<?php
require('conn.php');
require('functions.php');
require('session.php');
$id=guolv($_GET['id']);
//print_r($userdata);

?>

<!doctype html>
<html>
<head>
<meta charset="utf-8">
<meta name="viewport" content="width=device-width,initial-scale=1.0, user-scalable=no, minimum-scale=1.0, maximum-scale=1.0" />
<title>新闻-<?php echo $config['sitename']?></title>
 <link href="Css1/header.css" rel="stylesheet" type="text/css" />
<link href="Css1/home.css" rel="stylesheet" type="text/css" />
<script type=text/javascript > var app="/user" </script>
<script type="text/javascript" src="Scripts1/jquery.min.js"></script>
<script type=text/javascript src="Scripts1/jquery.common.js"></script>
</head>
 <style>
 body, h1, h2, h3, h4, h5, h6, dl, dt, dd, ul, ol, li, th, td, p, form, input, button, textarea, hr, article, footer, header, menu, nav, section {
margin: 0;
padding: 0;
}.help .mt{
            height:45px;
            line-height: 45px;
            background:#fff;
            border-bottom:1px solid #eae9ec;
            box-shadow: 2px 2px 2px #eae9ec;
            font-size:20px;
            text-align: center;
        }
        .help .mc{
            border-top:1px solid #dfdfdf;
            margin-top:10px;
            background:#fff;
        }
        .help .mc li{
		list-style-type:none
		}
        .help .mc li .help-tit{
            display: block;
            line-height: 1.5em;
            padding: 10px 5%;
            border-bottom:1px solid #dfdfdf;
            font-size:14px;
        }
        .help .mc li .help-tit::before{
            display: inline-block;
            content:"";
            width: 0px;
            height: 0px;
            border-top: 8px solid transparent;
            border-left: 8px solid #F0A944;
            border-bottom: 8px solid transparent;
            vertical-align: middle;
            margin:-4px 6px 0 0;
            transition:all .2s;
        }
        .help .mc li .help-txt{
            display: none;
            background:#f4f4f4;
            border-bottom:1px solid #dfdfdf;
            padding:5%;
            line-height: 2em;
            font-size:12px;
        }
		.help .mc li .help-txt img{WIDTH: expression(this.width > 640 && this.width > this.height ? 640 : true); BORDER-BOTTOM: #ccc 1px solid; max-width: 90%}
        .help .mc .drop .help-tit::before{
            -webkit-transform:rotate(90deg);
            transform:rotate(90deg);
        }
        .help .mc .drop .help-txt{
            display: block;
        }
        table {
            width: 100%;
            display: table;
            border-collapse: separate;
            border-spacing: 2px;
            border-color: gray;
            border-collapse: collapse;
            text-align: center;
            color: #333;
        }
        table th,table td{
            height:40px;
            line-height: 40px;
            border:1px solid #d9d9d9;
        }
        th{
            background:#c4d79b;
            font-weight: normal;
        }
.recommand .list ul>span,.recommand .list ul>li{animation:bounceInRight 0.5s forwards;-webkit-animation:bounceInRight 0.5s forwards;}
.recommand .list ul li.li-1{-webkit-animation-duration:0.6s;}
.recommand .list ul li.li-2{-webkit-animation-duration:0.7s;}
.recommand .list ul li.li-3{-webkit-animation-duration:0.8s;}
.recommand .list ul li.li-4{-webkit-animation-duration:0.9s;}
.recommand .list ul li.li-5{-webkit-animation-duration:1.0s;}
.recommand .list ul li.li-6{-webkit-animation-duration:1.1s;}
.recommand .list ul li.li-7{-webkit-animation-duration:1.2s;}
.recommand .list ul li.li-8{-webkit-animation-duration:1.3s;}
.back-bt {
	width: 70px;
	height: 70px;
	position: fixed;
	bottom: 10px;
	z-index:10;
}
.back-bt a {
	width: 49px;
	float: left;
    height: auto;
    margin-left: 15px;
    -webkit-tap-highlight-color:rgba(0,0,0,0.5);
}
.back-bt img {
	width: 49px;
}
.cata-bt {
	width: 70px;
	height:44px;
	position: fixed;
	bottom: 24px;
	right: 15px;
	z-index:99;
	background-color: #387ef5;
	border-radius: 44px;
	box-shadow: 0px 1.5px 2px 0 #000;
	margin-bottom: 10px;
	text-align: center;
}

.cata-bt a {
	width: 70px;
	height:44px;
	right: 0;
	-webkit-tap-highlight-color:rgba(0,0,0,0.5);
	text-decoration:none;
}
.cata-bt span {
	display:block;
	width:100%;
	text-align:center;
	line-height:44px;
	color: #fff;
	font-size: 12px;
	font-weight: bold;
	position:relative;z-index:10;
	text-decoration:none;

}</style>
<body class="mhome">

<?php include('header.php')?>
<?php
if(is_numeric($id)==false){
?>
 
<table width="100%" border="0" cellspacing="0" cellpadding="0">

</table>





<div class="help">
      
        <div class="mc">
            <ul>
            
            <?php
	$rows=$mysql->query("select * from `newsdata` order by `id` limit 0,10");
	foreach($rows as $row){
 
		

?>
            
            
                <li>
                    <span class="help-tit"><a href="news.php?id=<?php echo $row['id']?>" target="_blank"><?php echo $row['title']?></a></span>
          
                </li>
   <?php 
   
   }?>
            </ul>
        </div>
</div>
<!--推荐列表页 -->
<div class="recommand" style="display:block">
  <div class="list">
  <ul>
		
  </ul>
</div>
























<?php }else {?>
<div class="common-wrapper">
<div class="main" style="padding-top:0;">
<div style="color:#000;font-size:16px;padding:10px;margin:10px;line-height:24px;">
<?php
$row=$mysql->query("select * from `newsdata` where `id` in({$id}) limit 1");
?>
<span style="color:#f00;font-size:18px;font-weight:bold;"><?php echo $row[0]['title']?></span><br><br>
<?php echo $row[0]['content']?>
</div>
</div></div>
<?php }?>
<br><br><br>
 
</body>
</html>
